package rexsee.multimedia;

import rexsee.core.browser.Browser;
import rexsee.core.widget.DivDialog;

public class VideoDialog extends DivDialog {

	public VideoView videoView = null;
	private final String mUrl;
	private final boolean mLooping;

	public VideoDialog(Browser browser, String id, String url, String style, boolean looping) {
		super(browser, id, style);
		mUrl = url;
		mLooping = looping;
	}

	@Override
	public void start() {
		super.start();
		boolean keepScale = styleSheet.format.equalsIgnoreCase("fixscale");
		videoView = new VideoView(mBrowser, getDialogId(), mUrl, mLooping, keepScale);
		this.addChild(videoView);
	}

}
